package com.ruoyi.safety.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; //添加
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.safety.mapper.ElectricStatusDictMapper;
import com.ruoyi.safety.domain.ElectricStatusDict;
import com.ruoyi.safety.service.IElectricStatusDictService;

/**
 * 分站供电状态字典Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-11-06
 */
@Service
public class ElectricStatusDictServiceImpl extends ServiceImpl<ElectricStatusDictMapper, ElectricStatusDict> implements IElectricStatusDictService //修改
{
    @Autowired
    private ElectricStatusDictMapper electricStatusDictMapper;

    /**
     * 查询分站供电状态字典
     * 
     * @param id 分站供电状态字典主键
     * @return 分站供电状态字典
     */
    @Override
    public ElectricStatusDict selectElectricStatusDictById(Long id)
    {
        return electricStatusDictMapper.selectElectricStatusDictById(id);
    }

    /**
     * 查询分站供电状态字典列表
     * 
     * @param electricStatusDict 分站供电状态字典
     * @return 分站供电状态字典
     */
    @Override
    public List<ElectricStatusDict> selectElectricStatusDictList(ElectricStatusDict electricStatusDict)
    {
        return electricStatusDictMapper.selectElectricStatusDictList(electricStatusDict);
    }

    /**
     * 新增分站供电状态字典
     * 
     * @param electricStatusDict 分站供电状态字典
     * @return 结果
     */
    @Override
    public int insertElectricStatusDict(ElectricStatusDict electricStatusDict)
    {
        return electricStatusDictMapper.insertElectricStatusDict(electricStatusDict);
    }

    /**
     * 修改分站供电状态字典
     * 
     * @param electricStatusDict 分站供电状态字典
     * @return 结果
     */
    @Override
    public int updateElectricStatusDict(ElectricStatusDict electricStatusDict)
    {
        return electricStatusDictMapper.updateElectricStatusDict(electricStatusDict);
    }

    /**
     * 批量删除分站供电状态字典
     * 
     * @param ids 需要删除的分站供电状态字典主键
     * @return 结果
     */
    @Override
    public int deleteElectricStatusDictByIds(Long[] ids)
    {
        return electricStatusDictMapper.deleteElectricStatusDictByIds(ids);
    }

    /**
     * 删除分站供电状态字典信息
     * 
     * @param id 分站供电状态字典主键
     * @return 结果
     */
    @Override
    public int deleteElectricStatusDictById(Long id)
    {
        return electricStatusDictMapper.deleteElectricStatusDictById(id);
    }

    @Override
    public ElectricStatusDict selectElectricStatusDictByCode(String datum) {
        return electricStatusDictMapper.selectElectricStatusDictByCode(datum);
    }
}
